Password file ============= The format for entries in this file are... username,type,password or username,type,password,duplicate_to or aliasname,a,username,username,... where type is one of u,f,r u indicates an ordinary user f indicates a user that is allowed to start a remote console for the server or use mailcmd.exe with full remote rights. r indicates a user that is allowed to redirect their mail via a remote console or mailcmd.exe a indicates a alias the 'duplicate_to' field is an address to which to send duplicates of all mails for this user. If the field is prefixed with '!', only the headers are send, not the body of the message. Aliases can be 'virtual' mailboxes ( eg. "sales"), fully-qualified 'virtual' mailboxes (e.g. "sales@sub-domain.domain"), or wild-card qualified mailboxes (e.g. "*@sub-domain.domain" or just "@sub-domain.domain"). In the first case, "sales" is in effect sales@local-domain. The second form allows handling of mail for specific users in a domain that JSMail does not ordinarily handle mail for. In this case, JSMail will accept mail for sales@sub-domain.domain but reject/forward mail for everyone else @sub-domain.domain. The third case means that JSMail will accept mails for all users at sub-domain.domain at will route them to the expansion of that alias, regardless of the original mailbox (the part before the '@'). Reject file =========== Each line contains an address or a subject or a route to reject. If it is preceded by a '!' character, it is regarded as meaning 'accept' rather than 'reject' and the mail is not rejected regardless of any match. Address entries start with source: or destination:, subject entries start with subject: and route entries start received:. These keywords are the followed by a regular expression that describes the address/subject/path-line to reject. For example entry result ---------------------------------------------------------------- source:@myhost.com reject all mails from users at the myhost.com domain source:fred@host.com reject mails from fred@host.com entry result ---------------------------------------------------------------- source:@myhost.com reject all mails from users at the myhost.com domain source:!fred@myhost.com don't reject mails from fred@myhost.com In this example, all mails from the myhost.com domain would be rejected except those from fred@myhost.com entry result ---------------------------------------------------------------- subject:\$\$\$ reject all mails with subject containing "$$$" subject:^[Ss][Ee][Xx] reject all mails with subject starting with "SEX", upper or lower case NOTE: The regular expression begins immediately after the ':' - there can be NO spaces/tabs ( unless they are part of the expression ). Allow/Deny file =============== These files just contain a list of IP addresses in dotted quad form along with the service they pertain to and wether to allow or deny the connection. The general format is ALLOW_OR_DENY SERVICE ADDRESS E.g allow smtp 158.152.*.* This would allow any machine on the 158.152 network access to the SMTP (send) service. Possible values for ALLOW_OR_DENY are allow deny Possible values for SERVICE are smtp pop3 password remote all If there are only 'allow' entries, then any connection that does not match an 'allow' entry will be rejected. If there are only 'deny' entries, then any connection that does not match a 'deny' entry will be allowed. Otherwise, the last match in the file will determine whether the connection is allowed. Responders file =============== The reponders config file is of the form a,b,c,d or a,b,c or a,b,!,d or a,b where a = subject to look for b = text_file_to_return c = executable_to_run, possibly to generate b d = user_to_forward_mail_to ! = place holder - do not execute anything If an executable is given, it is called with the name of the file containing the original mail as its only parameter. Finger files ============ The finger files ( *.fgr ) are of the form Some text [WIDE] Some more Text The text before the [WIDE] marker is returned as the short form. The whole text ( without '[WIDE]' ) is retyrned as the long form. Scheduler ========= This controls the connection attempts and has the form [ras_entry_name1] connection1 connection2 connection3 [ras_entry_name2] connection4 connection5 Here, ras_entry_name is the name of an entry in the Dial up networking/RAS phonebook or the special entry 'LAN', which just tries to connect without attempting to dial first. Each connection is either a time to dial or an number of mails waiting to be delivered. For times, these are in the form DD HH:MM. You can replace any digit or day with a '*' to mean 'any' so FR 12:*5 would mean fridays at 12:05, 12:15, 12:25 etc A single number on a line on its own is interpreted as the number of mails in the outbound mail queue that will initiate a dial. You can specify the username, password and domain for the connection by adding the lines user: my_login_name password: my_pasword domain: my_domain after the header line. You can leave any or all of these three lines out. You can also specify whether a particular entry is for SMTP connections, POP3 connections or BOTH ( BOTH is the default ) by adding a line like type: SMTP The days of the week are abreviated to Monday MO Tuesday TU Wednesday WE Thursday TH Friday FR Saturday SA Sunday SU For example [MYISP] user: fred password: scooby domain: WORKGROUP type: SMTP * 12:00 SA 13:00 SU 5 would call the entry MYISP every day at 12:00, 1:00pm on saturdays and whenever there are 5 or more mails waiting to be sent to the outside world on sundays using the username 'fred', password 'scooby' and domain name 'WORKGROUP'. It would only send mails via SMTP but would not try to retrieve anything from a POP3 host. Ranges can be specified using a hyphen... eg MO-FR *:00 Would dial on the hour every hour monday to friday. If the entry in the brackets is prepended with a #, then JSMail will take any oportunity to use this connection. ie, an entry starting [#MYISP] will use any connection to MYISP when it happens, regardless of any specific times to connect given below. There is a special entry 'LAN' which does not actually attempt to dial an phonebook entry, but just assumes the connection has happened. This can be used to only make non dial-up connections at specific times. eg. [LAN] * *:00 would assume a connection exists every hour. This file can optionally be compiled using the JSMC utility. This creates a version of the file in binary format so that passwords etc in this file are not human-readable. By default, the output filename of JSMC is as the input file with '.jsm' appended. Once compiled, you can delete ( or move somewhere safe ) the non-compiled version. Subject file ============ This is a simple mapping between a subject pattern given by a regular expression and a local user name. The format is username:pattern Note that there can be NO spaces after the colon (unless they are part of the pattern ). POP3 account file ================= This consists of any number of entries of the form [pop3host] user:pop3username password:pop3password You can specify a particular TCP port for the connection by appending it to the hostname eg pop3host.com:110 The default port is 110. This file can optionally be compiled using the JSMC utility. This creates a version of the file in binary format so that passwords etc in this file are not human-readable. By default, the output filename of JSMC is as the input file with '.jsm' appended. Once compiled, you can delete ( or move somewhere safe ) the non-compiled version. Regular expressions ------------------- Simply stated, a regular expression lets you match strings not only by direct match, but also by extended matches, similar to, but much more powerful than the DOS wildcards. Regular expressions may be made up of normal characters and/or special characters, sometimes called metacharacters. The metacharacters have the following meanings. . A dot character matches any single character of the input line. ^ The ^ character does not match any character but represents the beginning of the input line. $ This does not match any character but represents the end of the input line. [bracket-expression] A bracket expression enclosed in square brackets is a regular expres- sion that matches a single character, or collating element. a) If the initial character is a circumflex ^, then this bracket expression is complemented. It shall match any character or collating-element except for the expressions specified in the bracket expression. b) If the first character after any potential circumflex is either a dash (-), or a closing square bracket (]), then that character shall match exactly that character; that is a literal dash or closing square bracket. c) Character ranges are specified by a dash (-) between two charac- ters, or collating sequences. This indicates all character or which collate between two characters. \ This character is used to turn off the special meaning of metacharac- ters. For example, \. only matches a dot character. Note that \\ matches a literal \ character. regexp* A regular expression regexp followed by * matches a string of zero or more strings that would match regexp. For example, A* matches A, AA, AAA and so on. regexp+ A regular expression regexp followed by + matches a string of one or more strings that would match regexp. regexp? A regular expression regexp followed by ? matches a string of one or zero occurrences of strings that would match regexp. Examples -------- abc matches any line of text containing the three letters abc in that order. a.c matches any string beginning with the letter a, followed by any char- acter, followed by the letter c. ^.$ matches any line containing exactly one character (the newline is not counted). .* [a-z]+ .* matches any line containing a word, consisting of lowercase alphabetic